package by.bsu.wp.ntfsp.model;

import java.util.HashMap;
import java.util.Map;

import org.jgrapht.graph.DefaultEdge;

public class ProductFlowEdge extends DefaultEdge {

	/**
	 * a list of size q that contains lambda coefficients the edge holds
	 */
	private Map<Integer, Integer> lambdaCoefficients;

	public ProductFlowEdge() {
		this.lambdaCoefficients = new HashMap<Integer, Integer>();
	}

	public Integer getLambdaCoefficient(Integer p) {
		return lambdaCoefficients.get(p);
	}

	public void setLambdaCoefficient(Integer p, Integer value) {
		lambdaCoefficients.put(p, value);
	}

	public Object getSource() {
		return super.getSource();
	}

	public Object getTarget() {
		return super.getTarget();
	}

	@Override
	public String toString() {
		return "ProductFlowEdge [lambdaCoefficients=" + lambdaCoefficients + ", getSource()=" + getSource()
				+ ", getTarget()=" + getTarget() + "]";
	}
	
	

}
